Printer and image processing apparatus

ABSTRACT

An input unit inputs RAW data. An image generating unit generates an image from the RAW data using a demosaicing processing. A print unit that prints the image.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation of U.S. patent application Ser. No.11/546,584, entitled “Printer and Image Processing Apparatus,” filedOct. 10, 2006, now U.S. Pat. No. 7,796,289, to which priority under 35U.S.C. §120 is claimed, the entire content of which is incorporatedherein by reference. This application also claims priority under 35U.S.C. §119 to Japanese Patent Application Nos. JP 2005-294958, filed inJapan on Oct. 7, 2005, JP 2005-295024, filed in Japan on Oct. 7, 2005,and JP 2005-295078, filed in Japan on Oct. 7, 2005, the entire contentsof which are incorporated herein by reference.

BACKGROUND OF THE INVENTION

The present invention relates to a printer and image processingapparatus, image processing method and image processing program.

Conventionally, as the data record format of an image input apparatussuch as a digital camera, there is known a RAW format in which the pixeldata of a color image sensor are digitally recorded as they are (seeJapanese Patent Publication No. 2005-33468). Since the color imagesensor normally carries thereon color filters respectively for R (Red),G (Green) and B (Blue) for each pixel, the RAW data having only onecolor component for each pixel are incomplete information as an imagerepresenting an object to be printed. Therefore, until a demosaicingprocessing (which is also referred to as a color falter arrangementinterpolation processing), in which at least a color component lackingin each pixel is estimated and interpolated by the color component of aneighboring pixel to thereby generate a color image having three colorcomponents for each pixel, are enforced on the RAW data, an imagerepresenting the object cannot be printed. In a printer themanufacturing and developing costs of which are restricted severely,there has been urgently needed the development of a technology forprinting an image using an RAW data file.

Meanwhile, image processing apparatus, which handle RAW data, has animage generating function which depends on the models of individualdigital cameras and uses at least a demosaicing processing, and afunction for correcting an image generated by the demosaicingprocessing. In this type of image processing apparatus, in some cases,there are executed similar processings in a preceding stage up togeneration of an image and in a correcting stage after generation of theimage. For example, in the preceding stage up to generation of theimage, there is executed a sharpness correcting processing forrecovering the lowered sharpness due to a low pass filter provided in adigital camera; and in the correcting stage after generation of theimage, there are executed a sharpness correcting processing for glossingover the setting errors of focus, stop and shutter speed as well as asharpness correcting processing according to the print resolution. Whenthese image processings, the objects of which are different but to whichthe same algorithm for correction is applied, can be executedcollectively, the processing time can be shortened. Also, because theimage processing essentially involves the deterioration of information,by reducing the number of times the image processings are executed,there is a possibility that the quality of the image can be improved.Further, when a pixel interpolation processing for enhancing theresolution is carried out after execution of a sharpness correctingprocessing, there is raised a problem that jaggies can appear clearly.Therefore, it is desirable that such sharpness correcting processingprior to execution of the pixel interpolation can be avoided.

SUMMARY OF THE INVENTION

It is therefore an object of the invention to allow a printer, themanufacturing and developing costs of which are severely restricted, toprint an image from RAW data.

It is also an object of the invention to provide an image processingapparatus, an image processing method and an image processing programwhich can optimize the process for generating a final image from RAWdata.

(1) In order to achieve the above objects, according to the invention,there is provided a printer, comprising: an input unit that inputs RAWdata; an image generating unit that generates an image from the RAW datausing a demosaicing processing; and, a print unit that prints the image.

The addition of a function to generate the image from the RAW data usingthe demosaicing processing to a printer makes it possible for theprinter to print the image from the RAW data.

(2) The image generating unit may generate the image of ageneral-purpose format from the RAW data, and the print unit may printthe image of the general-purpose format.

When generating an image from RAW data, by generating an image of ageneral-purpose format defined by a standard exceeding the framework ofa printer manufacturer, any printer, which is capable of printing animage of a general-purpose format, can print an image from RAW datawhile restricting the manufacturing and developing costs thereof.

(3) The printer may further comprises: a compressing unit thatcompresses the image for each block and storing the same into a storagemedium; and an expanding unit that expands the image stored in thestorage medium for each band to be printed, wherein the print unitgenerates print data from the expanded image for each band to be printedand, based on the print data, prints the image for each band to beprinted.

Generally, since the print data have tone control values (includingbinary values) corresponding to the number of colors of ink and tonerwith respect to the number of pixels corresponding to the printresolution, the data size is considerably larger than the image. Forthis reason, by generating the print data for each band to be printedand executing a printing operation for each band to be printed, astorage resource such as a memory can be saved. However, to execute animage processing such as a rotation processing within the printer, thewhole of the image must exist statically within a storage space. Forexample, a digital camera generally records an image in a format long inthe horizontal direction, whereas most of printers print the image longthe vertical direction in order to restrict the oblique movement ofprinting paper. Therefore, the printer's rotation processing isinevitably necessary. However, when, while the whole of an image is heldin the internal memory of a printer, the print data are also held in theinternal memory, there arises a problem that the necessary capacity ofthe internal memory is increased greatly. For this reason, theconventional printer executes a printing operation while readingdiscretely images stored in a removable memory for each band to beprinted. However, when trying to print an image generated from RAW data,the whole of images generated must be held and thus, when the images areheld in the internal memory of the printer, the manufacturing cost ofthe printer is inevitably increased to a great extent. This problem canbe solved by compressing the images generated from the RAW data for eachblock and storing them in a storage medium, expanding the compressedimages for each band to be printed, and generating print data from theexpanded images for each band to be printed. The reason for this isthat, by compressing the images for each band to be printed, the wholeof the images can be held in a memory space and also, while data in anarea not belonging to the band to be printed are held in the memoryspace in a compressed state, by expanding the images for each band to beprinted, the print data can be generated.

(4) The expanding unit may set the band to be printed so that the imageis divided in the horizontal direction.

When a horizontally long image (an image in which the number ofhorizontal direction pixels is larger than the number of verticaldirection pixels) is printed in the horizontal direction (when pixelsarranged in the horizontal direction are sequentially printed accordingto paper feed distances), or when a vertically long image is printed inthe vertical direction, the expansion of the images and the generationof the print data must be carried out for each band to be printed inwhich the image is divided in the horizontal direction. To print ahorizontally long image in the horizontal direction of the imagecorresponds to printing the image by rotating the same.

(5) The general-purpose format may be a JFIF format.

Since the JFIF format is the file format of a JPEG format image, it ishighly versatile.

(6) The general-purpose format may be an Exif format.

Since the Exif format is practically a standard file format for adigital camera, it is highly versatile.

(7) The compressing unit may compress the image irreversibly with aquantizing step width corresponding to the free capacity of the storagemedium.

Irreversible compression involved with quantization has an advantagethat, as the quantizing step width increases, the data size of the imagecan be reduced accordingly, whereas it has a problem that, as thequantizing step width increases, the deterioration of the quality of theimage becomes worse. In view of this, by giving priority to the imagequality when the free capacity of the storage medium is sufficient, andby giving priority to the printing while the image quality isdeteriorated when the empty capacity is insufficient, the handlingfacilitation of the printer can be enhanced.

(8) The printer may further comprises an user interface for previouslyinforming an user of the degree of deterioration of the quality of theimage caused by the compression and also for receiving a print cancelrequest from the user.

Provision of such user interface can prevent the image from beingprinted with disappointing image quality, thereby being able to enhancethe handling facilitation of the printer further.

(9) The storage medium may be an external storage medium.

By storing images generated from the RAW data into an external storagemedium such as a removable memory, a hard disk, and the internal memoryof an external system, even when the free capacity of the internalmemory is short, there can be enhanced a possibility that the images canbe printed from the RAW data.

(10) The printer may further comprises storage unit that stores theimage into an external storage medium, wherein the print unit prints theimage stored in the external storage medium.

The addition of a function for generating an image from RAW data using ademosaicing processing to the printer makes it possible for the printerto print the image from the RAW data. However, generally, print datahave tone control values (the tone control value includes a binaryvalue) corresponding to the number of colors of ink or toner withrespect to the number of pixels corresponding to the print resolutionand, therefore, the data size is considerably large when compared withthe image. In order to execute an image processing such as rotationwithin the printer, the whole of the image must be statically presentwithin a storage space. For example, while a digital camera generallyrecords an image in a format long in the horizontal direction, a printeroften prints the image long in the vertical direction in order toprevent paper from moving obliquely. Therefore, in the case of a printerof a stand-alone type, a rotation processing by the printer isindispensable. However, when the whole of the image is held in aninternal memory and at the same time the print data are also held in theinternal memory, there arises a problem that the necessary capacity ofthe internal memory must be increase greatly. For this reason, in aconventional printer, while discretely reading images stored in aremovable memory for every bands to be printed, a printing operation isexecuted. To print an image generated from RAW data, the whole of theimage generated must be held and, when the image is held by the internalmemory of the printer, the manufacturing cost of the printer isinevitably increased to a great extent. This problem can be solved bystoring the image generated from the RAW data into an external storagemedium such as a removable memory, a hard disk, and the internal memoryof an external system. The reason for this is that, by storing the imagegenerated from the RAW data into the external storage medium, there iseliminated the need to increase the capacity of the internal memory ofthe printer. Thanks to this, without increasing the manufacturing anddeveloping cost of the printer, the image can be printed from the RAWdata.

(11) the storage unit, when the printing of the image by the print unitmay be completed, removes the image from the external storage medium.

Such removal of the image after printed can prevent the image generatedregardless of the intention of a user from consuming uselessly thestorage area of the external storage medium.

(12) The storage unit may check whether the external storage medium isin a writable state or not and, when the external storage medium is inan unwritable state, requests a user to replace the external storagemedium.

When the user requested to replace the external storage medium replacesit with a writable external storage medium, the printer can keep onprinting.

(13) The storage unit may check the external storage medium for the freecapacity thereof and, when the external storage medium is short of thecapacity for storing the image, displays a file removal menu forremoving data stored in the external storage medium.

When the user removes a file according to the file removal menudisplayed, the free capacity of the external storage medium isincreased, so that the printer can keep on printing.

(14) The storage unit may check the external storage medium for the freecapacity thereof and, when the external storage medium is short of thecapacity for storing the image, requests a user to add another externalstorage medium.

When the user requested to add another external storage medium addsanother external storage medium having sufficient capacity, the printercan keep on printing.

(15) The storage unit, when the external storage medium is composed oftwo or more external storage mediums, may check the external storagemediums for their respective free capacity and stores the image into theexternal storage medium having free capacity capable of storing theimage therein.

By storing the image into an external storage medium having freecapacity capable of storing the image therein, even if one of theexternal storage mediums is short of free capacity, when anotherexternal storage medium has sufficient free capacity, the printer cankeep on printing without troubling the user.

(16) The storage unit may store the image into the external storagemedium with the hidden attributes thereof set.

Since the image is stored into an external storage medium for theconvenience of the printer which has generated the image regardless ofthe intention of a user, preferably, the hidden attributes of the imagemay be set.

(17) The storage unit irreversibly may compress the image with aquantizing step width corresponding to the free capacity of the externalstorage medium and stores the thus compressed image into the externalstorage medium.

The irreversible compression involved with quantization, on one hand,has an advantage that, as the quantizing step width increases, the datasize of the image can be reduced accordingly; but, on the other hand, itraises a problem that, as the quantizing step width increases, thedeterioration of the image quality becomes worse accordingly. In view ofthis, when the free capacity of the external storage medium issufficient, priority is given to the image quality and, when it isinsufficient, priority is given to the printing even if the imagequality is deteriorated. This can facilitate the handling of theprinter.

(18) According to the invention, there is also provided An imageprocessing apparatus, comprising; an input unit that inputs RAW data andattribute information about the RAW data; a setting unit that sets acorrection parameter based on the attribute information; an imagegenerating unit that generates an image from the RAW data using ademosaicing processing; and an image correcting unit that corrects theimage using the correction parameter.

Generally, in an image input apparatus such as a digital camera, to RAWdata, there is added attribute information which is necessary togenerate an image from the RAW data. The image generated based on suchattribute information is, as it were, under the control of the imageinput apparatus or the user thereof. However, as described above, when aprocessing to be executed for generating an image under the control ofthe image input apparatus or the user thereof based on such attributeinformation and a processing for correcting the image under the controlof the image input apparatus or the user thereof after generation of theimage are similar to each other, by carrying out the former and latterprocessings collectively, the quality of the final image can be enhancedand the processing time necessary up to generation of the final imagecan be shortened. According to the present invention, since a correctionparameter for correcting an image generated from RAW data is set basedon attribute information about a final image, processings to be executedrespectively for various purposes can unified into the correctingprocessing for correcting the image generated from the RAW data.

(19) The setting unit may generate a file of a general-purpose formatwith the image and the correction parameter stored therein, and theimage correcting unit corrects the image using the correction parameterstored in the file of the general-purpose format.

Software resources and hardware resources, which are necessary for theimage processing, can be saved by using them in common. That is, whetheran image is an image generated from RAW data by the image processingapparatus itself or an image generated by an external apparatus, whenthe image processing apparatus is capable of processing the images usingthe same software resources and hardware resources, the manufacturingand developing cost of the image processing apparatus can be reduced aswell as the developing time thereof can be shortened. Therefore, whenthe image generated from the RAW data by the image processing apparatusand the correction parameter set by the image processing apparatus basedon the attribute information of the RAW data are stored into the file ofthe general-purpose format, the manufacturing and developing cost of theimage processing apparatus can be reduced as well as the developing timethereof can be shortened.

(20) The image generating unit may not execute a sharpness correctingprocessing, and the image correcting unit may enforce a sharpnesscorrecting processing on the image using the correction parameter.

(21) The image correcting unit may enforce a resolution conversionprocessing on the image and enforces the sharpness correcting processingon the image with the resolution conversion processing enforced thereon.

By unifying the sharpness correcting processing to be executed beforeexecution of the resolution conversion and the sharpness correctingprocessing to be executed after execution of the resolution conversion

into the sharpness correcting processing to be executed after executionof the resolution conversion, the quality of the image and theprocessing speed can be enhanced.

(22) The resolution conversion processing may be a resolution conversionprocessing to provide a print resolution.

The resolution conversion processing to provide a print resolution is aresolution conversion processing which is enforced last. Therefore, whenthe sharpness correcting processing is not executed before theresolution conversion processing to the print resolution but thesharpness correcting processings for two or more purposes are executedcollectively after execution of the resolution conversion processing tothe print resolution; the sharpness correcting processings can beoptimized.

(23) The attribute information may include information about the modelof an image input device having generated the RAW data, and the settingunit may set the correction parameter according to the modelinformation.

If the model information can be specified, it is possible to set acontrol value for a sharpness correcting processing to be executed forrecovering the lowered sharpness due to a low pass filter provided in animage input apparatus such as a digital camera. Thus, by setting acorrection parameter for the sharpness correcting processing aftergeneration of the image based on the model information of the imageinput apparatus, the quality of the image and the processing speed canbe enhanced.

(24) The attribute information may include a fixed operation value for asharpness correcting processing for recovering the lowered sharpness dueto a low pass filter provided in an image input apparatus, and thesetting unit may set the correction parameter according to the fixedoperation value.

If a fixed operation value for a sharpness correcting processing forrecovering the lowered sharpness due to a low pass filter provided in animage input apparatus exists as attribute information about the RAWdata, by setting a correction parameter for the sharpness correctingprocessing after generation of the image based on the fixed operationvalue, the quality of the image and the processing speed can beenhanced. The operation value for a sharpness correcting processing forrecovering the lowered sharpness due to a low pass filter provided in animage input apparatus can be decided in only one meaning. In view ofthis, the operation value for a sharpness correcting processing forrecovering the lowered sharpness due to a low pass filter provided in animage input apparatus is herein referred to as a fixed operation valuefor a sharpness correcting processing for recovering the loweredsharpness due to a low pass filter provided in an image input apparatus.

(25) The attribute information may include a variable operation valuefor a sharpness correcting processing set according to the operation ofthe image input apparatus, and the setting unit may set the correctionparameter according to the fixed operation value and the variableoperation value.

If a variable operation value for a sharpness correcting processing setaccording to the operation of the image input apparatus exists asattribute information about the RAW data, by setting a correctionparameter for the sharpness correcting processing after generation ofthe image based on the fixed operation value, the quality of the imageand the processing speed can be enhanced. The operation value for asharpness correcting processing set according to the operation of theimage input apparatus varies according to the operation of the imageinput apparatus. In view of this, the operation value for a sharpnesscorrecting processing set according to the operation of the image inputapparatus is herein referred to as a variable operation value for asharpness correcting processing set according to the operation of theimage input apparatus. Referring to such variable operation value, forexample, in a portrait photograph mode, there is set a variableoperation value which lowers the sharpness of the image; and, in alandscape photograph mode, there is set a value which enhances thesharpness of the image.

(26) According to the invention, there is also provided a method forprocessing an image, comprising: inputting RAW data and informationabout the attribute of the RAW data; setting a correction parameterbased on the attribute information; generating an image from the RAWdata using a demosaicing processing; and correcting the image using thecorrection parameter.

By setting a correction parameter for correcting an image generated fromRAW data based on the attribute information about the RAW data,processings to be executed for two or more purposes can be unified intoa correction processing for correcting the image generated from the RAWdata.

(27) According to the invention there is also provided an imageprocessing program for operating a computer, comprising: an input unitthat inputs RAW data and information about the attribute of the RAWdata; a setting unit that inputs a correction parameter based on theattribute information; an image generating unit that generates an imagefrom the RAW data using a demosaicing processing; and an imagecorrecting unit that corrects the image using the correction parameter.

By setting a correction parameter for correcting an image generated fromRAW data based on the attribute information about the RAW data,processings to be executed for two or more purposes can be unified intoa correction processing for correcting the image generated from the RAWdata.

(28) According to the invention there is also provided an imageprocessing apparatus, comprising: an input unit that inputs RAW data andinformation about the attribute of the RAW data; a setting unit thatsets a correction parameter based on the attribute information; an imagegenerating unit generates an image from the RAW data using a demosaicingprocessing; and an output unit that outputs a file in which thecorrection parameter and the image are stored.

By setting a correction parameter for correcting an image generated fromRAW data based on the attribute information about the RAW data, evenwhen the image processing apparatus having generated the image from theRAW data itself does not correct the image, processings to be executedfor two or more purposes can be unified into a correction processing forcorrecting the image generated from the RAW data.

(29) According to the invention, there is also provided a method forprocessing an image, comprising: inputting RAW data and informationabout the attribute of the RAW data; setting a correction parameterbased on the attribute information; generating an image from the RAWdata using a demosaicing processing; and outputting a file in which thecorrection parameter and the image are stored.

By setting a correction parameter for correcting an image generated fromRAW data based on the attribute information about the RAW data, evenwhen the image processing apparatus having generated the image from theRAW data itself does not correct the image, processings to be executedfor two or more purposes can be unified into a correction processing forcorrecting the image generated from the RAW data.

(30) According to the invention, there is also provided an imageprocessing program for operating a computer, comprising: an input unitthat inputs RAW data and information about the attribute of the RAWdata; a setting unit that sets a correction parameter based on theattribute information; an image generating unit that generates an imagefrom the RAW data using a demosaicing processing; and an output unitthat outputs a file in which the correction parameter and the image arestored.

By setting a correction parameter for correcting an image generated fromRAW data based on the attribute information about the RAW data, evenwhen the image processing apparatus having generated the image from theRAW data itself does not correct the image, processings to be executedfor two or more purposes can be unified into a correction processing forcorrecting the image generated from the RAW data.

By the way, the respective functions of the two or more unit provided bythe present invention can be realized by a hardware resource thefunction of which can be specified by its structure itself, a hardwareresource the function of which can be specified by a program, or acombination of these hardware resources. Also, the respective functionsof the two or more unit are not limited to those that can be realized byhardware resources which are physically independent of one another.Also, the present invention not only can be specified as an invention ofan apparatus but also can be specified as an invention of a program, asan invention of a storage medium with the program recorded therein, andas an invention of a method.

BRIEF DESCRIPTION OF THE DRAWINGS

The above objects and advantages of the present invention will becomemore apparent by describing in detail preferred exemplary embodimentsthereof with reference to the accompanying drawings, wherein:

FIG. 1 is a typical view of an embodiment according to the invention;

FIG. 2 is a block diagram of the schematic structure of a printeraccording to an embodiment of the invention;

FIG. 3 is a flow chart of the operation of a printer according to anembodiment of the invention;

FIG. 4 is a flow chart of the flow of a processing to be executed inStep S136 in FIG. 3;

FIG. 5 is a flow chart of the flow of a processing to be executed inStep S138 in FIG. 3;

FIG. 6 is a typical view of an embodiment according to the invention;

FIG. 7 is a view of screen transition according to an embodiment of theinvention; and

FIG. 8 is a typical view of messages and menus according to anembodiment of the invention.

DETAILED DESCRIPTION OF THE EMBODIMENTS

Hereinafter, description will be given below in the following order ofan embodiment in which the invention is applied to a printer of astand-alone type with reference to the accompanying drawings.

1. Structure of Printer

2. Operation of Printer

-   -   2-1. RAW data print setting    -   *Free capacity securing processing    -   *Development correction set processing    -   2-2 RAW data processing    -   2-3 Image print processing

3. Other embodiments

1. Structure of Printer

FIG. 2 is a block diagram of the schematic structure of a printer 1 towhich the invention is applied. The printer 1 is a printer of a socalled stand-alone type which can read therein RAW data and images in ageneral-purpose format from a removable memory 10 and can execute aprinting operation based on these data. Also, the printer 1 can directlyinput therein RAW data and images in a general-purpose format from anexternal system such as a digital camera 30, a PC (Personal Computer) 32and a portable telephone terminal with a camera 34 and also can executea printing operation based on these images.

An external IF (Inter Face) 20 serving as input unit and storing unitincludes a USB controller, a USB connector and the like which are usedto communicate with the external system such as the digital camera 30,PC (Personal Computer) 32 and portable telephone terminal with a camera34. The communication standard is not limited to the USB but there canbe used any other standard such as an IEEE 1394, an infrared ray, andEthernet (registered trademark). Owing to provision of a USB hostfunction in the external IF 20, when the external system corresponds toa USB mass storage standard, the printer 1 can gain access to a storagemedium which belongs to the external system. Also, when a commonly usedstorage medium such as a hard disk is provided within a LAN to which theprinter 1 is connected, the printer 1 can output data to a storagemedium under the control of the external system. That is, even when astorage medium is under the control of the external system, the printer1 not only can provisionally hold the images generated from the RAW datain the storage medium but also can read out the provisionally heldimages from the storage medium. Also, the printer 1 itself may have ahard disk device, which makes it possible to increase the storagecapacity of the printer 1.

A removable memory controller (RMC) 12 serving as the input unit and thestoring unit is connected through a connector (not shown) to theremovable memory 10 serving as an external storage medium and controlsdata transfer between the removable memory 10 and RAM 14. The removablememory 10 may be a card-type flash memory (a so called memory card) ormay be any other nonvolatile storage medium capable of repetitivewriting.

An image processing unit 16 is composed of image processing LSIs andDSPs which cooperate together with a CPU 22 in executing an imagecorrection processing such as a sharpness correction processing and atone correction processing, a print division processing, a half toningprocessing, an interlace processing, and other processings at a highspeed. By the way, these processings may also be executed according to aprogram processing by the CPU 22. Also, a JPEG compression/expansionfunction may be added to the image processing unit 16, which makes itpossible to speed up the JPEG compression/expansion processing.

A print unit 18 serving as printing unit and storing unit includes arecording head for forming an image on paper according to an ink jetmethod based on the print data, a mechanism for shuttling the recordinghead, a paper feed and discharge mechanism and the like. By the way, asthe printing method, there can be employed any one of ink jet method,laser method, thermal method, dot impact method and the like.

The RAM 14 is a volatile memory in which a control program and data tobe processed by the control program, for example, the RAW data, imagesand print data are provisionally stored.

The CPU 22, which serves as image generating unit, compressing unit,expanding unit, storing unit and printing unit, executes a controlprogram stored in a flash memory 24, whereby the CPU 22 not onlyexecutes image processings such as a processing for generating imagesfrom the RAW data and a JPEG compression/expansion processing using ademosaicing processing but also controls the respective parts of theprinter 1 to control the execution of a printing operation. The controlprogram may be transferred from a computer readable storage medium tothe flash memory 24 or may be transferred from a remote server through anetwork to the flash memory 24.

An operation unit 26 serving as user interface includes an operationbutton, a jog dial and other various buttons which are used to receivethe menu operation and print request of the user. When a specific buttonis depressed in a specific mode, various requests corresponding to themode are input to the printer 1.

A display unit 28 serving as user interface includes a FPD (Flat PanelDisplay) 27 (see FIG. 7) such as an LCD, a graphic controller and thelike. A frame memory area necessary for display of characters and imageson the FPD 27 may be secured in an exclusive memory provided in thedisplay unit 28, or may also be allocated to a partial area of the RAM14. Data written into the frame memory area are read out periodically bythe graphic controller, whereby the characters and images to bedisplayed on the FPD 27 can be updated.

An access indicator 19 includes a light such as an LED for informing auser of data transfer between the RMC 12 and RAM 14, and furtherincludes a controller for the light.

2. Operation of Printer

Now, FIG. 3 is a flow chart of the operation of the printer 1. Theprocessing shown in FIG. 3 can be started when, in a file-to-be-printedselect mode, a RAW data file is selected as an object to be printed by auser. In the file-to-be-printed select mode, thumbnail images stored inthe RAW data file and reduced images of a VGA size for display aredisplayed on the FPD. The images to be displayed can be specified by theanalysis of the file header. When the display image of a VGA size or thelike larger than the thumbnail image having 160×120 pixels aredisplayed, the user is able to estimate the print results with moreaccuracy. Therefore, when it is found from the manufacturer and model ofa digital camera stored in the file header that an image larger than thethumbnail image is stored in the RAW data file, the larger image is tobe displayed. When no image is stored in the RAW data file (in thepresent specification, description is given assuming that the RAW dataare not images), may also generate a reduced image of the order of a VGAsize according to a simpler high speed algorithm. Specifically, forexample, by generating an image having a resolution one half that of theRAW data in each of the vertical and horizontal directions, thedemosaicing processing can be speeded up; and, by omitting a whitebalance correction processing, a luminance correction processing, apseudo color restrict processing and the like, the generation of thereduced image can be speeded up.

When the RAW data file is selected as an object to be printed, theprinter 1 executes two main processings. They are a RAW data print setprocessing and a RAW data print processing. In the RAW data print setprocessing, the printer 1 checks the removable memory 10 for the freecapacity thereof and, when the free capacity is not sufficient, theprinter 1 requests its proper measure from the user or receives an imagedevelopment correction set change request from the user. In the printprocessing, the printer 1 reads therein the RAW data from the removablememory 10, generates an intermediate image of a general-purpose formatfrom the RAW data, stores the generated intermediate image into theremovable memory 10, and, while reading therein the intermediate imageof a general-purpose format generated by itself from the removablememory 10, executes an operation to print the intermediate image.

By the way, with regard to the data format of the intermediate image tobe handled in the process in which the printer 1 prints the image fromthe RAW data, in the present embodiment, description is given of a JPEGformat as an example. However, the invention is not limited to this butthere may also be employed other general-purpose formats such as a JPEG2000 format, a BMP format and a TIFF format, or there may also beemployed a data format which is optimized by sacrificing the generalpurpose function thereof. Also, as for a format for a file includingother attribute information than the intermediate image, similarly, inthe present embodiment, description is given of an Exif format as anexample. However, there may also be used a file format which is apartially changed version of an Exif standard, or there may be used aJPEG file format of a JFIF type, or may be used a file format which isoptimized by sacrificing the general purpose function thereof.

2-1. RAW Data Print Setting

In Step S050, the printer 1 checks whether the removable memory 10 is ina writable state or not. For example, it is checked whether a writeinhibit check member is in a write inhibit position and the removablememory 10 is thereby inhibited from writing or not. By the way, when twoor more removable memories 10 can be connected to the RMC 12 at the sametime, if one or more removable memories 10 are in a writable state, theprinter 1 may judge that the removable memory 10 is in a writable state.In this case, the writable removable memory 10 is set as an object intowhich the intermediate image is to be stored. Or, only when a removablememory exclusively used to store the intermediate image therein isconnected to the RMC 12 separately from a user's removable memory 10with the RAW data file stored therein, the printing operation based onthe RAW data may be executed.

When the removable memory 10 is not in a writable state, the printer 1displays on the FPD 27 a message which requests the replacement of theremovable memory 10. For example, as shown in FIG. 8 (A), on the FPD 27,there is displayed a message to the effect that “Replace the removablememory with a writable removable memory”. Or, on the FPD 27, there mayalso be displayed a message to urge the removal of the write inhibitstate of the removal memory 10. For example, on the FPD 27, there may bedisplayed a message that “The memory card is set in a write inhibitstate. Remove the write inhibit state of the memory card”. By the way,the printer 1 may also request the replacement of the removable memoryor may request the removal of the write inhibit state of the removablememory through sound. While a message is being displayed, when apreviously determined operation button provided on the operation unit 26is depressed, the printer 1 goes back to Step S050 and resumes theprocessing.

In Step S100, the CPU 12 checks the removable memory 10 for the freecapacity thereof. Specifically, for example, the data size of theintermediate image is estimated for each compression quality from thenumber of pixels of the RAW data to be printed and the like and, whenthe free capacity is short even for the lowest quality, the freecapacity is judged to be absolutely short. In this case, free capacitysecuring processings in Step S104 and in its following steps areexecuted. When the free capacity is sufficient even for the highestquality, the free capacity is judged to be sufficient. In this case,development correction setting processings in Step S120 and in itsfollowing steps or printing processings in Step S130 and in itsfollowing steps are executed. And, when the free capacity isinsufficient for the highest quality but is sufficient for the lowestquality, the free capacity is judged to be somewhat short and thus aprocessing in Step S102, which will be discussed next, is executed.

In Step S102, there is informed a user to the effect that the freecapacity of the removable 10 is not sufficient and thus the printing ismade possible by lowering the compression quality or by removingunnecessary data. The printer 1, specifically, displays such a messageas shown in FIG. 8 (B) on the FPD 27 to thereby request the choice ofone of print cancellation, data removal and compression ratio increase.When the print cancellation is chosen, the processing on the RAW data tobe printed is terminated. When canceling the printing, the printer 1displays on the FPD 27 a message to the effect that “Execution ofprinting is impossible and the printing is cancelled”, and then theprinter 1 cancels the print processing. For the choice of the dataremoval, free capacity securing processings in Step S106 and in itsfollowing steps are executed. For the selection of the compression ratioincrease, the free capacity of the removable memory 10 and the highestquality within the restriction of the number of pixels of the RAW dataare displayed on the FPD 27 by words such as “high”, “medium” and “low”;and, when the compression quality is approved, a quantizing table changeprocessing in Step S116 is executed. Approval or rejection of thecompression quality can be input, for example, when a previouslydetermined button provided on the operation unit 26 is pressed down in aState where a message shown in FIG. 8 (C) is being displayed. Whenrejection of the compression quality is chosen, the message moves to thescreen shown in FIG. 8 (B). In order to check the free capacity of theremovable memory 10 and the highest compression quality within therestriction of the pixel number of the RAW data, the CPU 12, forexample, refers to a table which shows correspondence between the freecapacity, the number of pixels and the compression quality and executesa previously decided operation with these elements as variables.

In Step S116, there is set a quantizing table which corresponds to thecompression quality approved by the user. The quantizing table is atable which prescribes quantizing step widths stage by stage accordingto DCT coefficients. As the quantizing step width broadens, the loweringof the image quality after expansion becomes worse; and, as thequantizing step width narrows, the lowering of the image quality afterexpansion is restricted accordingly. By the way, in Step S100, when thefree capacity is judged to be sufficient, there is used a quantizingtable of the highest quality which is a default setting.

*Free Space Securing Processing

In Step S104, the printer 1 requests the user to select data removal forthe purpose of increasing the free capacity of the removal memory 10, orprint cancellation. Specifically, for example, the printer 1 displays amenu shown in FIG. 7 on the FPD 27 and receives the selection of thedata removal or print cancellation. When a predetermined button of theoperation unit 26 is depressed, the data removal or print cancellationis selected. When the print cancellation is chosen, the processing onthe RAW data to be printed is terminated.

When the data removal is chosen, the printer 1 displays a file removalmenu 33 on the FPD 27 (Step S106). On the file removal menu 33, forexample, according to the operation of the button or the rotation of thejog dial, there are displayed sequentially images to be removed one byone. Also, on the file removal menu 33, there are also displayed thenecessary free capacity and the data size of the images being displayedtogether with the images to be removed. The user can select a file to beremoved by operating the button or jog dial to display the images to beremoved.

When a removal request occurs (Step S108), the CPU 22 allows the RMC 12to remove the file to be removed from the removable memory 10 (StepS110). Referring specifically to the occurrence of the removal request,for example, when the user presses down a given button on the fileremoval menu 33, the removal request occurs while a file being selectedat the then time is as a target to be removed. When the file is removedfrom the removable memory 10, the processings in Step S100 and in itsfollowing steps are repeated.

When the removal rejection occurs (Step S112), the CPU 22 terminates theprinting processing. Specifically, the removal rejection occurs, forexample, when the user depresses a given button in a state where theabove-mentioned message is being displayed.

*Development Correction Set Processing

In Step S120, when a development correction set change request occurs,there are executed the following development time correction setprocessings. The development correction set change request occurs when apreviously determined given button is depressed.

In Step S122, the printer 1 sets a develop correction operation valueaccording to the operation of the user. Specifically, for example, whena dialog screen shown in FIG. 8 (D) is displayed on the FPD 27 and an EVoperation (development correction operation value), for example, “+1” isselected, the operation value, “+1”, is set and, at the same time, thereis set a control value which raises the luminance of the image by 1 inthe EV (Exposure Value) conversion, that is, a luminance control valuewhich allows the lightness of the image to be double in the luminanceconversion. By the way, there may also be set other control value thanthe control value for the luminance correction processing, for example,an operation value for the sharpness correction processing or whitebalance correction processing. Here, the sharpness operation value thatcan be set in this manner is corrected in the below-mentioned manner andis then added to an intermediate image as “image correction controlinformation for the purpose of obtaining a desired print result”.

In Step S124, the CPU 22 executes an image processing corresponding tothe develop correction operation value on a reduced image displayed onthe FPD 27 in the mode of selection of the file to be printed.Specifically, on the reduced image of a VGA size stored in the file tobe printed, there are executed correction processings (such as aluminance correction processing, a sharpness correction processing, anda white balance correction processing) to which there is applied acontrol value set in Step S122.

In Step S126, the printer 1 updates the reduced image displayed on theFPD 27 in the file to be printed selection mode into a reduced imageafter retouched. Specifically, the reduced image in a frame memory areais changed and written into the reduced image after retouched, and thedisplay on the FPD 27 is updated. Since the reduced image afterretouched is displayed on the FPD 27, the user, while confirming theretouched results on the screen, can set the development correctionoperation values repetitively until a satisfactory result can beobtained. By the way, as described above, the printer 1 may also executesuch a display updating operation as reflects the operation value forthe sharpness correction processing or white balance correctionprocessing.

2-2. Printing Processing

When a print request occurs in Step S130, there are executed thefollowing printing processings. The print request occurs when apredetermined given button is depressed.

In Step S132, the CPU 22 allows the access indicator 19 to startblinking. The blinking of the access indicator 19 continues until theprinting operation is terminated. The printer 1, during execution of theprinting operation, reads therein the RAW data and intermediate imagesfrom the removal memory 10 and writes the intermediate images into theremoval memory 10. Accordingly, when the removal memory 10 is removedfrom the RMC 12 during execution of the printing operation, there is apossibility that unremovable intermediate images can be left in theremovable memory 10 and the FAT of the removable memory can be destroyedto thereby disable the printer 1 from reading the data properly. Theblinking operation of the access indicator 19 during execution of theprinting operation can prevent the occurrence of the above problemcaused by the user's careless removal of the removal memory 10.

In Step S134, the printer 1 displays a progress bar on the FPD 27 tothereby start a processing for guiding the printing progress state tothe user. The display of the printing progress state continues until theprinting operation is ended. Specifically, the progress bar notifies theuser in real time what percentage the RAW development processing hasprogressed. For example, when the processing has finished about 20%,there is displayed a progress bar which shows the progress correspondingto 20% with respect to a scale of 100%. Normally, in a printer, sincethe processing speed of the CPU is slow due to the restriction of themanufacturing cost thereof, it takes several minutes to generate animage from the RAW data. The display of the progress bar is veryeffective, because it can eliminate the irritated feeling of the userand the user can know by it that the processing has been progressingpositively.

In Step S136, an intermediate image is generated from the RAW data andthe intermediate image is stored into the removable memory 10.

In Step S138, the intermediate image is read from the removable memory10, print data are generated from the intermediate image, and a printingoperation based on the print data is executed.

In Step S140, the progress bar provides a 100% display and the displayof the printing progress state is ended.

In Step S142, the CPU 22 terminates the blinking of the access indicator19.

*RAW Data Processing

FIG. 4 is a flow chart of the details of the flow of the RAW dataprocessing in the above-mentioned step S136.

In Step S200, the CPU 22 analyzes attribute information about the fileto be printed to specify the manufacturer of a digital camera, the modelof the digital camera, photograph information (date of photograph, stop,shutter speed and the like), print control information, developmentcontrol information and the like. The print control information includesthe specification of a print size, the specification of the number ofpaper to be printed, image correction control information for obtaininga desired print result, and the like. As a standard for transmission ofthe print size specification and print paper number specification fromthe digital camera to the printer, there is well known a DPOF (PrintOrder Format). As a standard for transmission of the image correctioncontrol information for obtaining a desired print result from thedigital camera to the printer, there are well known a PIM (Print ImageMatching) standard and an Exif Ver 2.2 standard. The development controlinformation includes a sharpness operation value for recovering thelowered sharpness caused by a low pass filter, an optical black value,gain information about each chromatic color component, luminancecorrection information, information about the arrangement of the colorfilter of an area image sensor, information for color space conversionfrom a device space color to sRGB color space or the like, gammacorrection information, and other information. Since the developmentcontrol information is peculiar to each digital camera, informationabout a file header is analyzed in every cameras and the analyzed resultthereof is applied to a processing to be executed in the following step.As a general-purpose standard for the development control information,there is proposed a DNG standard. Referring to an essential differencebetween the image correction control information for obtaining a desiredprint result and the development control information, the former isdefined as information which can be applied only to images, whereas thelatter is defined as information which can be basically applied to aprocessing for generating images from the RAW data.

Processings in Steps S202 to S220, which will be discussed below indetail, are executed in a block unit. That is, in the first step S202,the RAW data of a block to be printed are read from the removable memory10 into the CPU 22 and the processed results thereof are stored into theRAM 14. In the following steps, the data of a block to be processed areread into the CPU 22 and the processed results thereof are stored intothe RAM 14. According to the 422 system of the JPEG standard, Cb and Crcomponents are sampled in the horizontal direction and; for every Y, Cband Cr components, DCT operation processings are enforced on every blockhaving vertical direction 8 pixels×horizontal direction 16 pixels, withthe result that an image is encoded in every block having verticaldirection 8 pixels×horizontal direction 16 pixels. Therefore, thevertical direction width of the block is set for 8 pixels or integermultiples of 8 pixels, while the horizontal direction width of the blockis set for 16 pixels or integer multiples of 16 pixels. To execute aprocessing with the vertical direction width set for 8 pixels isefficient and the efficiency of use of a memory is also high.

Now, FIG. 1 is a typical view to show how to hold the data of a block tobe processed until the print data are generated from the RAW data. Asolid line expresses data size which occupies a memory space statically,while a hatching expresses the size of the data of the block to beprocessed. A broken line expresses the size of a memory spaceaccumulatively necessary for processing of the whole of the RAW data. Bythe way, while general RAW data are recorded in the tone of 12 bits perpixel, in the processing step, in order to enhance the access efficiencyfor every pixel, it is reasonable to handle a word (16 bits) per pixel.In the present embodiment, description is given assuming that the RAWdata are an expression for 16 bits.

In Step S202, the CPU 22 carries out an optical black compensationprocessing based on an optical black value. The optical black valueexpresses a value obtained when the quantity of charges accumulated in alight receiving element, which is disposed in the image sensor of animage input device and is prevented against entry of light, is A/Dconverted. That is, the optical black value shows the zero level of theluminance of the pixel. When there exists an optical black area withinthe RAW data, the mean value of the optical black area is used as anoptical black value. When an optical black value is previouslycalculated by the image input device and is stored in the file header,this value is used. The optical black compensation processing is aprocessing which is important to establish the linearity of processingsto be executed in the following steps thereof. In an optical blackcompensation processing, a value, which is expressed by an optical blackvalue obtained from the file header, is regarded as black, and a valueexpressed by the optical black value is subtracted from the whole pixelvalue of the RAW data. Generally, for the RAW data of 12 bits, theoptical black value is about 32/4095-64/4095 and thus the number of bitsare not varied by the optical black compensation processing. Data to beprocessed in Step S202, as shown in S1 in FIG. 1, are stored in theremovable memory 10, and the processed results in Step S202 are storedin the RAM 14 in the same data size as the size before they areprocessed.

In Step S204, the CPU 22 executes a white balance correction processingbased on gain information about every chromatic color components. Thespectral radiation energy distribution of an object varies naturallywhen illumination environments differ, whereas human beings perceivesthe color of the same object as the same color even when theillumination environments differ. This tendency is referred to as theconstant property of a color (color constancy). On the other hand, theimage sensor accumulates the electric charges corresponding to therespective chromatic color components (in the present embodiment, theyare described as RGB) in a balance corresponding to the spectralradiation energy distribution of an object. For this reason, forexample, in order that an object to be perceived as a achromatic color(for example, white) in the daytime outside in a fine weather can beexpressed by achromatic pixels (pixels having the same RGB value), thereis necessary a color balance correction processing which corrects thecolor balance of the respective RGB components. In the color balancecorrection processing, using gain information specified on every RGBcomponents, the respective RGB components are basically multiplied by aconstant. As a result of this, although the number of bits representingthe pixel value increases or decreases, because the original RAW datahaving 12 bits per pixel are processed with 16 bits per pixel, the sizeof the block data to be provisionally held by the RAM 14 does not varybefore and after the execution of the processing in Step S204. By theway, with regard to the constant (normally, about 0.5-4) which ismultiplied on the respective RGB components, a value as the gaininformation calculated as the optimum coefficient by the digital cameramay be used as it is, or a value calculated from the RAW data accordingto a previously determined algorithm by the CPU 22 may be used.

In Step S206, the CPU 22 enforces a luminance correction processingbased on the luminance correction information. With regard to thisluminance correction processing, for example, when the physical exposureof the digital camera is inappropriate, to recover such inappropriateexposure, there is executed an exposure correction operation after anobject is photographed by the digital camera; and, when luminancecorrection information corresponding to the exposure correctionoperation is stored in the file header, the present luminance correctionprocessing is enforced. By the way, the luminance component may bemultiplied by a constant to thereby correct the luminance, or therespective chromatic components may be multiplied by a constant tothereby correct the luminance. Specifically, when a +1 EV exposurecorrection is executed on the RAW data, a processing for multiplying theluminance components by a double coefficient is executed. When a −1 EVexposure correction is executed on the RAW data, a processing formultiplying the luminance components by a half coefficient is executed.As a result of this, although the number of bits representing the pixelvalue increases or decreases, because the original RAW data having 12bits per pixel are processed with 16 bits per pixel, the size of theblock data to be provisionally held by the RAM 14 does not vary beforeand after the execution of the processing in Step S206.

In Step S208, the CPU 22 executes a demosaicing processing correspondingto the arrangement of the color filter of an area image sensor. Thedemosaicing processing is a processing in which, basically, mutuallyadjoining pixels each having a chromatic color component (for example,one of R, G and B components) per pixel compensate their lackingchromatic color components with each other. As a result of this, therespective pixels, each of which had only one of R, G and B components,can have three (R, G and B) components and, therefore, the size of theblock data to be held provisionally by the RAM 14, as shown in S2 inFIG. 1, becomes three times when compared with the site before theprocessing.

In Step S210, the CPU 22 executes a color reproduction processing. Sincethe values of the respective color components of the RAW data depend onthe spectral sensitivity of the image sensor of the image inputapparatus, they do not correspond to tristimulus values prescribed by ageneral-purpose standard such as an sRGB or the like. The colorreproduction processing is a processing in which color lights expressedby the RAW data used as input values are expressed by stimulus valuesprescribed by a general-purpose standard such as an sRGB or the like. Inother words, in the color reproduction processing, there are generatedstimulus values expressing proper colors according to thegeneral-purpose standard (the values of colors measured by a colorimeteras the same colors as the colors of a photographed target object) usinga linear map or a nonlinear map for every three chromatic colorcomponents. Specifically, the stimulus values of the respective pixelsare converted using a matrix operation of 3×3 or a three-dimensional LUT(Look Up Table) on the three (R, G and B) components. The matrix andthree-dimensional LUT used in this conversion can be obtained asdevelopment control information from the file header, or a matrix or athree-dimensional LUT previously defined by a printer vendor accordingto the models can be set according to model information obtained fromthe file header. The size of the block data to be held by the RAM 14does not vary before and after the processing in Step S210.

In Step S212, the CPU 22 enforces a color space conversion processingfor converting the color space from the RGB color space to the YCbCrcolor space. This is a simple color space linear conversion processingfor adapting the intermediate image to the JPEG format. As a result ofthis, the block data to be held by the RAM 14 provide such a state asshown in S3 in FIG. 1. The size of the block data to be provisionallyheld by the RAM 14 does not vary before and after the processing in StepS212.

In Step S214, the CPU 22 enforces a sub sampling processing according tothe 422 method. As a result of this, only the Cb and Cr color differencecomponents are reduced in space in the horizontal direction. That is,the Y component is not processed but the Cb and Cr components aresampled in space by a mean value in every two adjoining pixels. As aresult of this, the size of the block data to be dynamically held by theRAM 14, as shown in S4 in FIG. 1, is ⅔ (=⅓+(⅓)×(½)+(⅓)×(½) when comparedwith the size before the processing.

In Step S216, the CPU 22 executes a pseudo color restrict processing. Inan image sensor including a color filter having a Bayer arrangement, thenumber of light receiving elements in R and B is one half the number oflight receiving elements in G, owing to the demosaicing processing,aliasing is easy to appear in the R and B components. A pseudo colorgenerated due to this can be restricted by a flattening processing usinga median filter or the like.

In Step S218, the CPU 22 executes a tone reproduction processing. Thelightness perceived by human being does not correspond to the luminancethat is the photometric quantity of the image sensor. Generally, theluminance is converted by a logarithmic function (for example, y=x(1/2.2) according to a Weber/Fechner hypothesis insisting that thequantity of perception is proportional to the logarithm of the stimulusquantity. By the way, in order to avoid a tone loss due to saturation,it is possible to execute transformation in which the tone is graduallyrestricted in the highlight area. The transformation is executed using,for example, a LUT which is defined optimally for every models ofdigital cameras.

In Step S220, the CPU 22 carries out a JPEG compression processing. TheJPEG compression processing is an encoding processing composed of acombination of quantization and Huffman encoding, in which a processingis enforced on every blocks each having horizontal direction 8pixels×vertical direction 8 pixels. For the quantization, there isapplied a given quantizing table which has been previously determined ora quantizing table set in the above-mentioned step S116. A quantizingstep width is set in such a manner that, in a block unit, the size ofthe data to be stored into the removable memory 10 can be, for example,about ⅙-¼ the size thereof before execution of the processing. By theway, as described above, the algorithm is not limited to the JPEG butany one of other algorithms may be used, provided that it encodes thedata for every blocks.

By repetitively enforcing processings in Steps S202 to S220 on the blockdata that have been JPEG compression processed, the block data areaccumulatively stored into the other area of the RAM 14 (that is, theother area than the area of the RAM 14 into which the block data priorto execution of the JPEG compression are stored). In a state where theprocessings in Steps S202 to S220 have been carried out repetitively upto the final block (in a state that is judged “yes” in Step S222), inthe other area of the RAM 14, as shown in S5 in FIG. 1, there are heldthe whole of intermediate images of a JPEG format generated from the RAWdata.

In Step S224, the CPU 22 arranges the file format of the intermediateimages into the Exif format, carries out an output processing to theremovable memory 10, and removes the intermediate image file of the Exifformat provisionally held by the RAM 14 at the time when the outputprocessing to the removable memory 10 is terminated. As a result ofthis, as shown in S6 in FIG. 1, the whole of the intermediate image fileof the Exif format is held by the removable memory 10, while the data tobe print processed that are held by the RAM 14 are entirely eliminatedprovisionally. Specifically, like a quantizing table, informationnecessary for expansion of the intermediate images, photographinformation (date of photograph, stop, shutter speed and the like),print control information, image correction control information forobtaining a desired print result, and other similar information areadded as file header information to thereby generate the intermediateimages of the Exif format, the intermediate image file is stored intothe removable memory 10, and the file size as well as the table andhidden attributes and the like of the file are stored into the FAT ofthe removable memory 10. The intermediate image file generated as aresult of the development processing is stored into the removable memory10 according to the convenience of the printer 1, which has generatedthe file, regardless of the intention of the user and, therefore,preferably, the table and hidden attributes of the file may be set as a“hidden file”.

By the way, when the RAM 14 has such a sufficient capacity as to be ableto eliminate the need for execution of the output processing to theremovable memory 10, there is no need to remove the intermediate imagefile of the Exif format from the RAM 14. Of course, in that case, theoutput processing for outputting the intermediate image file to theremovable memory 10 is not necessary, either. Also, there is alsopossible a processing which does not hold the whole of the intermediateimage file of the Exif format in the RAM 14. For example, after, whenenforcing the processing in the above-mentioned step S220, the outputprocessings to the removable memory 10 are carried out for every blocksand the output processings to the removal memory 10 for all blocks arecompleted, information necessary as the Exif file may be stored into theremovable memory 10.

By the way, in the present embodiment, a sharpness correction processingis not enforced on the intermediate images which are stored into theremovable memory 10. Since an image input apparatus such a digitalcamera includes a low pass filter for prevention of aliasing, it isnecessary to enforce a sharpness correction processing for recoveringthe lowered sharpness of the images caused by the low pass filter of theimage input apparatus. Therefore, in the conventional system whichgenerates images from the RAW data, such sharpness processing has beenenforced before the images are output. However, when a resolutionconversion processing is enforced on the images on which a sharpnesscorrection processing has been enforced, there is a tendency that thequality of the images can be deteriorated. On the other hand, in theprocess for printing the images, a resolution conversion processing anda sharpness correction processing to the print resolution are alwaysexecuted. This is because, as the print size increases, the image ismore out of focus and, as the print size decreases, the image issharper.

In view of this, in the present embodiment, in order that the sharpnesscorrection processings can be executed at a time when the resolution isconverted so as to match the print resolution or after the resolution isconverted so as to match the print resolution, the information for theprinter 1 to be able to apply a control value for the sharpnesscorrection processings to the images is transmitted to the processingsto be executed thereafter as image correction information for obtaininga desired print result; and, the above-mentioned sharpness correctionprocessings include a sharpness processing for recovering the loweredsharpness due to the low pass filter of the image input apparatus andsharpness correction processings to be executed for attaining theirrespective purposes (for example, a purpose of optimizing the appearanceof a picture by lowering the sharpness of a portrait image and byraising the sharpness of a landscape image, and a purpose of optimizingthe sharpness of a picture according to the print sizes). The thustransmitted image correction control information corresponds to acorrection parameter.

Specifically, for example, it is assumed that, in the RAW data file, asharpness operation value is set for “+1” as the image correctioncontrol information for obtaining a desired print result. In the case ofa conventional printer (for example, a printer adapted to PIM), when thesharpness operation value of an image to be processed is set for “+1”, auniform control value corresponding to a sharpness operation value “+1”is applied to the images, which are generated by any model of digitalcamera, in a sharpness correction processing. On the other hand, in theprinter 1 according to the present embodiment, for example, even when asharpness operation value is set for “+1” in the RAW data file to beprocessed as the image correction control information for obtaining adesired print result (by the way, conventionally, there has not beenknown a digital camera in which the image correction control informationfor obtaining a desired print result is added to the RAW data file),since a sharpness operation value (for example, “+1” or “+2” to “0”,“+2” or “+3” to “+1”) with the property of a low pass filter for eachdigital camera taken into account is transmitted as the sharpnessoperation value of the intermediate image, control values differing inevery digital cameras are applied in the sharpness correction processingthat will be discussed later. Also, this applies similarly to thedevelopment correction operation values which are set in Step S122. Evenwhen a sharpness operation value “+1” is set as the developmentcorrection operation value, a sharpness operation value (for example,“+1” or “+2” to “0”, “+2” or “+3” to “+1”) with the property of a lowpass filter for each digital camera taken into account is transmitted asthe sharpness operation value of the intermediate image. The property ofa low pass filter in each digital camera can be specified by attributeinformation such as development control information and mode informationstored in the RAW data file. Therefore, the CPU 22 sets the imagecorrection control information for obtaining a desired print resultbased on the attribute information such as the development controlinformation and mode information attached to the RAW data.

By the way, a method for transmitting the control information with thedevice property of the image input apparatus such as a digital camerataken into account is not limited to a method for recording the controlinformation in the file header of the intermediate image but the controlinformation may also be transmitted through a closed API within theprinter 1.

*Image Print Processing

Now, FIG. 5 is a flow chart of the details of the flow of the imageprint processing in the above-mentioned step S138.

The processing shown in FIG. 5 is substantially the same as a processingwhich is carried out when an image of the JPEG format or the like isselected as an object to be printed. That is, the printer 1 according tothe present embodiment executes an image print processing using entirelythe same software resource and hardware resource whether an object to beprinted is the RAW data or the image. As a result of this, the timenecessary for development of the printer 1 can be shortened as well asthe manufacturing and developing costs of the printer 1 can be reduced.

In Step S300, the CPU 22 analyzes the header of an intermediate imagefile which is a file to be printed to thereby specify informationnecessary for expansion of the intermediate image, photographinformation, print control information, image correction controlinformation for obtaining a desired print result, a file size and thelike, and sets a control value necessary for printing of theintermediate image based on these pieces of information. Specifically,for example, the CPU 22 sets a quantizing table, a control value for asharpness correction processing, a control value for a color balancecorrection processing, a control value for a tone correction processing,a control value for a memory color correction processing, the number ofpaper to be printed, the size of printing paper, a printing resolutionand the like. By the way, as the print control information, there may beused the DPO data or the like attached to the image to be printed or, ofcourse, the user may set control values for the print size, printresolution and the like through the operation unit 26.

Processings in steps from S302 to S306, which will be described below indetail, are executed in the unit of a band to be printed. Normalprinting is sequentially executed starting from one side of the imagetoward the opposing side thereof. Therefore, the processings advancesequentially in a band unit along the printing direction. That is, inthe first step S302, compressed data in a band to be printed are readout from the removable memory 10 into the CPU 22 and the processedresult thereof is stored into the RAM 14; and, in the following steps,the data of the band to be printed are read from the RAM 14 into the CPU22 and the processed result thereof is stored into the RAM 14. The bandsto be printed are set along the printing direction. The image of adigital camera is normally an image which is longer in the horizontaldirection at a ratio of 3 to 2 and, in order that a printer having anarrow width can print an image having a large area, it is reasonable toprint the image sequentially in the long side direction thereof.Therefore, generally, firstly, an image long in the horizontal directionis turned 90 degrees to convert it to an image which is long in thevertical direction, and the vertically long image is printed in the longside direction from one of the short sides thereof toward the other.

For example, as shown in FIG. 6, when a horizontally long image isprinted sequentially in the horizontal direction of the image (in thedirection where the band to be printed is processed in the orderstarting from A to G), that is, when a 90-degree turned image isprinted, the band to be printed is set in such a manner that the imageis divided in the horizontal direction. In this case, as shown in FIG.6, since the direction of generation of the intermediate image (theorder according to which one line is generated in the horizontaldirection in the order of a broken arrow mark, and the remaining linesare generated sequentially in the numerical order) is different 90degrees from the direction of printing of the intermediate image (theorder according to which the band to be printed is processed in theorder of A to G), the generation of the intermediate image and theprinting of the intermediate image cannot be processed sequentially in aserial manner. Therefore, in this case, it is necessary to hold thewhole of the intermediate image statically in a memory space. Assumingthat the intermediate image is held statically in a memory space withoutcompressing the intermediate image, the RAM 14 must hold the whole ofthe intermediate image in a state in which the data size is shown by thewhole of broken lines in S2 in FIG. 1.

In the printing operation, since the intermediate image serving asinformation about the source to be printed and the print data serving asoutput information must be held in the RAM 14, the necessary capacity ofthe RAM 14 is fairly large. For this reason, according to the presentembodiment, by generating a compressed intermediate image, the memoryresource is saved, which makes it possible to develop and print the RAWdata in an environment having a limited memory resource. In addition,according to the present embodiment, since the compressed intermediateimage is held by the removable memory 10, the capacity of the RAM 14 tobe mounted in the printer 1 can be made substantially equal to that of aprinter not adapted to the RAW data.

By the way, the above-mentioned effects are not limited only to the casewhere the image is rotated and printed. For example, even when the wholeof the image is analyzed for setting the image correction control value,the effect provided by compressing the intermediate image can workadvantageously. Also, for example, when the destination of theintermediate image is a device having a low data transfer speed such asa hard disk device, or when the communication speed between the printer1 and an external device serving as the destination of the outputthereof is low, the compression effect of the intermediate image canwork advantageously.

In Step S302, the CPU 22, while reading therein the block data withinthe band to be printed sequentially from the removal memory 10, expandsthe block data and stores the resultant YCbCr image within the band tobe printed into the RAM 14. As a result of this, the data of the band tobe printed that are held by the RAM 14 provide a state shown in S7 inFIG. 7.

In Step S304, the CPU 22, while cooperating together with the imageprocessing unit 16, corrects the image of the band to be printed.Specifically, there are executed a resolution conversion processing, asharpness correction processing, a color balance correction processing,a tone correction processing, a memory color correction processing andthe like to which the control values set in Step S300 are applied. Atthe then time, the data on the band to be printed that are held by theRAM 14 provide a state shown in S7 or S8 in FIG. 1 which is expressed bya color space corresponding to the contents of the processings. Thesharpness correction processing is executed after conversion of theresolution and, as described above, there is applied a control valuewith the lowered sharpness due to the low pass filter of the image inputapparatus such as a digital camera or the like taken into account. Inthis manner, according to the present embodiment, since a sharpnesscorrection processing is not executed before conversion of theresolution, the quality of the printed image can be enhanced. The colorbalance correction processing, tone correction processing, memory colorcorrection processing and the like may be carried out after or beforethe resolution conversion.

In Step S306, the CPU 22 generates the print data on the band to beprinted from the image of the band to be printed, while the print unit18 carries out a printing operation based on the print data. At the thentime, the print data on the band to be printed that are held by the RAM14 provide a state shown in S9 in FIG. 1.

When the processings in Steps from S302 to S306 are completed up to thefinal band to be printed (when “Yes” is judged in Step S308), the CPU 22allows the RMC 12 to remove the intermediate image held in the removablememory 10 (Step S310). To remove the intermediate image after printingcan prevent the useless consumption of the storage area of the removablememory 10 by the intermediate image that is generated regardless of theintention of the user. By the way, when the number of paper to beprinted is two or more, the intermediate image may be held by theremovable memory 10 until the printing of all the number of paper iscompleted or the generation and removal of the intermediate image may berepeated every time one copy is printed.

In a printer according to an embodiment of the invention which has beendescribed heretofore, by storing the image generated from the RAW datainto the removable memory 10, the image can be printed from the RAW datawithout increasing the capacity of the RAM 14. Therefore, the image canbe printed from the RAW data without increasing production cost anddevelopment cost.

3. Other Embodiments

In the above-mentioned free capacity securing processing, descriptionhas been given of an example in which, when the free capacity of theremovable memory 10 is short, the file removal menu 33 is displayed tothereby secure the free capacity. However, alternatively, addition ofanother removable memory may be requested of the user. Specifically, forexample, as shown in FIG. 8 (E), the printer 1 may display on the FPD 27a message telling that “The free capacity of the removable memory isshort. You are requested to add another removable memory having an emptycapacity of 1.2 MB bytes or more.”, or may output the sound of the samecontents. The term “1.2 MB bytes” in the message is the data size of theintermediate image that can be estimated from the RAW data selected atthe then time. When this message is displayed, the user replaces thecurrently used removable memory with another removable memory having anempty capacity of 1.2 MB bytes or more and, in a state where the messageis being displayed, depresses a given button provided on the operationunit 26. In response to this, the printer 1 repeats the processings inStep S100 and in the following steps and executes the free capacitysecuring processing to thereby confirm the free capacity of theremovable memory. When the free capacity is sufficient, the removablememory substituted provides the destination of the intermediate image.When the replacement of the removable memory is rejected, the printer 1executes an error processing.

Also, when two or more external storage mediums, which are not limitedto the removable memories, can be connected to the printer 1, the freecapacity of the respective external storage mediums may be checked andan intermediate image may be stored in each of the external storagemediums the free capacity of which is equal to or larger than the datasize of the intermediate image. For example, as shown in FIG. 2, it isassumed that a digital camera 30, a personal computer 32 and a portabletelephone 34 are connected to the printer 1 as external storage mediums.Also, it is assumed that two or more removable memories can be connectedto the RMC 12 of the printer 1 and a hard disk (not shown) is built inthe printer 1. In this case, the printer 1 checks these external storagemediums for their free capacity in a given order. The checking order canbe set arbitrarily but, preferably, the external storage mediums such asthe removable memories and built-in hard disk directly connected to theprinter 1 may be checked first. When there is found an external storagemedium having free capacity equal to or larger than the data size of theintermediate image, the thus found external storage medium provides theoutput destination of the intermediate image. In this manner, when theprinter 1 is structured such that it can find out an external storagemedium having free capacity equal to or larger than the data size of theintermediate image, the printing operation can be carried outcontinuously without troubling the user, thereby being able to furtherenhance the efficiency of the printing operation when printing the RAWdata. When there has not been found out any external storage mediumhaving free capacity equal to or larger than the data size of theintermediate image after all, the printer 1 may display the file removalmenu 33, or may request the replacement of the removable memory, or maycancel the printing operation.

In the above-mentioned embodiments, description has been given of anexample in which the intermediate image is output to the outside of theprinter 1 but, as has been already described, the whole of theintermediate images may be held in the RAM 14 serving as a storagemedium. Even in this case, by compressing the intermediate images, it ispossible to reduce the capacity that is additionally necessary in theRAM 14 to print the image from the RAW data.

Also, in the above-mentioned embodiment, description has been givenheretofore of an example in which the invention is applied to a printerof a stand-alone type. However, the invention can also applied to a PC(Personal Computer), a digital camera, an image scanner and the likerespectively not having a function to correct an image. Specifically,the PC and image input apparatus can execute processings up to theabove-mentioned RAW data processing and also can output a file in whichan intermediate image obtained as the result of the execution of theprocessings and the correction control information of the image forobtaining a desirable print result are stored. In this case, preferably,the format of the correction control information and output file formatmay correspond to a general-purpose standard such as PIM, EXIF andVer2.2.

1. A printer, comprising: a first input unit configured to input RAWdata; a second input unit configured to input first image data of ageneral purpose format; an image generating unit configured to generatesecond image data of the general-purpose format from the RAW data inputby the first input unit using a demosaicing processing; and a print unitconfigured to print both the first image data and the second image data;wherein the image generating unit generates the second image data basedon the RAW data using the demosaicing processing and a compressionprocessing for each of a plurality of blocks and stores the second imagedata into a storage medium; wherein the printer further comprises anexpanding unit configured to expand the second image data stored in thestorage medium for each of a plurality of bands to be printed, therebyforming expanded second image data; wherein the print unit generatesprint data from the expanded second image data for each of the pluralityof bands to be printed and, prints an image for each of the plurality ofbands to be printed based on the print data.
 2. The printer as set forthin claim 1, wherein the expanding unit sets a band to be printed so thatan image represented by the second image data is divided in a horizontaldirection.
 3. The printer as set forth in claim 1, wherein the secondimage data is compressed according to a free capacity of the storagemedium.
 4. The printer as set forth in claim 3, further comprising auser interface for previously informing a user of a degree ofdeterioration of a quality of the first image data and the second imagedata caused by the compression processing and for receiving a printcancel request from the user.
 5. The printer as set forth in claim 1,wherein the storage medium is an external storage medium.
 6. A printer,comprising: a first input unit configured to input RAW data; a secondinput unit configured to input first image data of a general purposeformat; an image generating unit configured to generate second imagedata of the general-purpose format from the RAW data input by the firstinput unit using a demosaicing processing; a print unit configured toprint both the first image data and the second image data; and a storageunit configured to store the second image data into an external storagemedium, wherein the print unit acquires the first image data and thesecond image data from the external storage medium and prints the firstimage data and the second image data, wherein the storage unitcompresses the second image data according to a free capacity of theexternal storage medium and stores the compressed second image data intothe external storage medium.